# Contributer: Baruch Burstein <bmburstein at gmail dot com>

pkgname=cloc
pkgver=1.84
pkgrel=1
pkgdesc="Count lines of code"
arch=('any')
url="https://github.com/AlDanial/cloc"
license=('GPL')
depends=('perl' 'perl-Algorithm-Diff' 'perl-Regexp-Common' 'perl-Parallel-ForkManager')
source=(${pkgname}-${pkgver}.tar.gz::https://github.com/AlDanial/cloc/archive/${pkgver}.tar.gz)
sha256sums=('b88a3adc669c15a9a32975095090708ba4eee5a73b8498369fae14be5b8a37d4')
noextract=(${pkgname}-${pkgver}.tar.gz)

prepare() {
  [[ -d ${pkgname}-${pkgver} ]] && rm -rf ${pkgname}-${pkgver}
  tar -xzvf ${pkgname}-${pkgver}.tar.gz -C ${srcdir} || true
}

package() {
  cd ${pkgname}-${pkgver}/Unix
  make DESTDIR="${pkgdir}" install
}
